// 知识接口
import config from "./config";

var domain = config.getDomain;

var pageCount = config.getPageCount;

var DUIXIN_API =  domain + '/index.php?v=1&appid='+config.getAPPID+'&appsecret='+config.getAPPSECRET+'&';

export default  {

	//导航
	getDuixin_daohang(code,uid) {
		var url = DUIXIN_API + 's=duixin&c=daohang&m=index';
		return url;
	},
	// 详情
	getDuixin_xiangqing(id){
		var url = DUIXIN_API + '&s=duixin&c=duixin&m=index&id='+id;
		return url;
	},
	// 列表
	getDuixin_list(obj) {
		var url = DUIXIN_API + '&s=duixin&c=liebiao&m=index&pagesize=' + pageCount + '&page=' + obj.page;
		if (obj.categories!= 0) {
		  url += '&catid=' + obj.categories;
		}
		if(obj.uid || obj.code){
			url += '&api_auth_uid='+obj.uid+'&api_auth_code='+obj.code;
		}
		return url;
	}

	


	
	
};